<div class="productlist">
    <table id="" cellpadding="0" cellspacing="0" border="0" width="100%">
        <tr>
            <td>
                <?php foreach ($aryConfCategory as $key => $value) {
                ?>
                    <div id="">
                        <div class="listtitle">
                            <div class="left">
                                <a href="<?php echo $root_page ?>/danhmuc/<?php echo $value['category_id']; ?>/<?php echo $value['category_name_filter']; ?>.html" title="<?php echo $value['category_name']; ?>" ><h1><?php echo $value['category_name']; ?></h1></a>
                            </div>
                            <div class="clear"></div>
                        </div>

                        <div class="list">
                            <table cellspacing="0" cellpadding="0" border="0">
                                <tbody>
                                    <tr>
                                    <?php if (is_array($aryProduct[$value['category_id']])) {
                                    ?>
                                    <?php $i = 1;
                                        foreach ($aryProduct[$value['category_id']] as $key => $product) {
 ?>
                                            <td valign="bottom">
                                                <div class="item">

                                            <?php
                                            $productHiglight = str_replace("\n", '<br>', $product['product_highlight']);
                                            $productHiglight = str_replace("\r", '<br>', $productHiglight);
                                            $productHiglight = str_replace("\"", '', $productHiglight);

                                            $product_promotional = str_replace("\n", '<br>', $product['product_promotional']);
                                            $product_promotional = str_replace("\r", '<br>', $product_promotional);
                                            $product_promotional = str_replace("\"", '', $product_promotional);
                                            ?>

                                           
                                                    <a class="tooltip" href="<?php echo $root_page ?>/sanpham/<?php echo $product['product_id']; ?>/<?php echo $product['product_title_filter']; ?>.html">
                                                    <?php if ($product['product_type_id'] == 1) { ?>
                                                        <div class="image_empty">
                                                            &nbsp;</div>
                                                    <?php } ?>

                                                    <div class="image">
                                                        <div class="divvalign">
                                                            <div class="divvalign2">
                                                                <img data-original="<?php echo $sub_domain; ?>/images/upload/thumbnail/<?php echo $product['product_main_image']; ?>" src="<?php echo $sub_domain;?>/images/common/grey.gif" alt="<?php echo $product['product_title']; ?>" title="<?php echo $product['product_title']; ?>">
                                                            </div>
                                                        </div>
                                                    </div>
                                                </a>
                                                <div class='name'>
                                                    <a href="<?php echo $root_page ?>/sanpham/<?php echo $product['product_id']; ?>/<?php echo $product['product_title_filter']; ?>.html">
<?php echo $product['product_title']; ?>
                                                    </a>
                                                </div>
<?php if ($product['product_price_vnd_km'] != 0 && $product['product_price_active_km'] == 1) { ?>
                                                        <div style="text-decoration: line-through;">
<?php echo number_format($product['product_price_vnd_km'], 0, ',', '.') . '&nbsp;VNĐ'; ?>
                                                    </div>
                                                    <div class="price">
<?php echo number_format($product['product_price_vnd'], 0, ',', '.') . '&nbsp;VNĐ' ?>
                                                    </div>
<?php } else { ?>
                                                        <div class="price">
<?php echo ($product['product_price_vnd'] != 0) ? number_format($product['product_price_vnd'], 0, ',', '.') . '&nbsp;VNĐ' : '<a onclick="MyController.OverlayChat();" style="color: red;">Call</a>'; ?>
                                                    </div>
<?php } ?>
                                                </div>
                                                <pre class="hidden"><?php echo $product['product_title'];?><img class="img_tooltip" title="<?php echo $sub_domain;?>/images/upload/large/<?php echo $product['product_large_image']; ?>"></pre>
                                            </div>
                                        </td>
<?php if ($i % 5 == 0) { ?>
                                                    </tr><tr>
                                    <?php } ?>
                                    <?php $i++;
                                                } ?>
<?php } ?>

                                        </tr>
                                    </tbody>
                                </table>
                            </div>

                        </div>
<?php } ?>


            </td>
        </tr>
    </table>
</div>